<template>
  <div class="home-container">
    <div class="content">
      <h1 class="main-title">华夏文明可视化系统</h1>
      <div class="subtitle">探索中华五千年文明，传承文化瑰宝</div>
      <div class="module-grid">
        <router-link to="/feiyi" class="module-card">
          <div class="card-content">
            <i class="el-icon-collection"></i>
            <h2>文化遗产</h2>
            <p>探索世界文化遗产，感受历史文明</p>
          </div>
        </router-link>
        <router-link to="/scenery" class="module-card">
          <div class="card-content">
            <i class="el-icon-picture"></i>
            <h2>湖光山色</h2>
            <p>领略中国自然风光，品味山水之美</p>
          </div>
        </router-link>
        <router-link to="/poem" class="module-card">
          <div class="card-content">
            <i class="el-icon-notebook-2"></i>
            <h2>诗词歌赋</h2>
            <p>欣赏古典文学艺术，传承文化精髓</p>
          </div>
        </router-link>
        <router-link to="/story" class="module-card">
          <div class="card-content">
            <i class="el-icon-house"></i>
            <h2>家传轶事</h2>
            <p>传承家族历史，延续文化血脉</p>
          </div>
        </router-link>
      </div>
      <!-- 添加底部边栏 -->
    <bottom-bar />
      </div>
  </div>
</template>

<script>
// 引入BottomBar组件
import BottomBar from '@/components/BottomBar.vue'
export default {
  name: 'HomePage',
  components: {
    BottomBar
  }
}
</script>

<style scoped>
.home-container {
  width: 100%;
  height: 100vh;
  background: url('/static/img/shouye.jpg') no-repeat center center;
  background-size: cover;
  display: flex;
  flex-direction: column;  /* 垂直排列 */
  justify-content: space-between;  /* 内容与底部间距 */
  position: relative;
}

.home-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: none; /* 完全移除遮罩 */
}

.content {
  position: relative;
  z-index: 1;
  text-align: center;
  color: #fff;
  padding: 20px;
  flex-grow: 1;  /* 占据剩余空间 */
}

.main-title {
  font-size: 68px;
  font-family: "楷体", serif;
  margin-bottom: 20px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
  color: #164ae8; 
}

.subtitle {
  font-size: 24px;
  margin-bottom: 60px;
  color: #f0f0f0;
}

.module-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
}

.module-card {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 15px;
  padding: 30px;
  text-decoration: none;
  color: #fff;
  transition: all 0.3s ease;
  backdrop-filter: blur(5px);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.module-card:hover {
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.2);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.card-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
}

.card-content i {
  font-size: 40px;
  color: #f0f0f0;
}

.card-content h2 {
  font-size: 28px;
  margin: 0;
  font-family: "楷体", serif;
}

.card-content p {
  font-size: 16px;
  margin: 0;
  color: #f0f0f0;
}

.scroll-footer {
  display: flex;
  justify-content: center;
  margin-top: 60px;
  align-items: center;
}


@media (max-width: 768px) {
  .module-grid {
    grid-template-columns: 1fr;
  }
  
  .main-title {
    font-size: 36px;
  }
  
  .subtitle {
    font-size: 20px;
  }

}
</style> 